import { ref } from 'vue'

const Example = {
  name: 'Example',
  setup() {
    const count = ref(0)

    return () => (
      <div class={`p-4 ${count.value > 0 ? 'bg-green-100' : 'bg-red-100'}`}>
        <button
          class="px-4 py-2 bg-blue-500 text-white rounded"
          onClick={() => count.value++}
        >
          点击次数：
          {count.value}
        </button>
      </div>
    )
  },
}

export default Example
